<?php
namespace app\index\controller;

use app\common\controller\Base;
use app\index\model\LRegister as LRegisterModel;

/**
 * 游戏服务器
 */
class Lregister extends Base
{

    use \app\index\controller\traits\CurlRequest;

    /**
     * 控制器初始化
     * @return   void
     */
    public function _initialize()
    {
        //基类授权
        //
        parent::_initialize();
        $this->model = new LRegisterModel();
    }

    public function testGetRegTotal()
    {

        $date = '2017-11-24';
        $res  = $this->model->getRegTotal($date);

        dump($res);
    }

    public function testGetRegCid()
    {

        $date = '2017-11-24';
        $res  = $this->model->getRegCid($date);

        dump($res);
    }

    public function testGetNewRecord()
    {

        $date = date("Y-m-d");
        $res  = $this->model->getNewRecord();
        $res  = json_decode($res, true);

        dump($res);
    }
    public function getLTV($reg, $calc)
    {
        return $this->model->getLTV($reg, $calc);
    }
}
